<?php
namespace app\controller;
use app\BaseController;
use think\Image;
class img extends BaseController
{
    public function index()
    {
        $image = Image::open("image.jpg");
        echo $image->width();
        echo $image->height();
        echo $image->type();
        echo $image->mime();
        dump( $image->size() );

        $image->water('logo.png',5)->save("image_mini.jpg");
    }
}